package com.sfy.auth.common.entity;

/**
 * @Author: sfy
 * @Date: 2024/4/13 17:51
 * @Description: 自定义分页
 */
public class PageInfo {

    private Integer pageNo = 1;

    private Integer pageSize = 20;


    public Integer getPageNo() {
        if (pageNo == null || pageNo < 1) {
            return 1;
        }
        return pageNo;
    }

    public Integer getPageSize() {
        if (pageSize == null || pageSize < 1 || pageSize > Integer.MAX_VALUE) {
            return 20;
        }
        return pageSize;
    }
}
